<%
response.setHeader("Cache-Control", "no-cache"); 	
response.setHeader("Pragma", "no-cache"); 	
response.setDateHeader("Expires", -1); 
%>

<%@ page import="br.com.cea.security.*"%>
<%@ page import="br.com.cea.security.beans.*"%>
<%@ page import="java.util.*"%>


<strong>Dados do HEADER...</strong>
USER_UID: <%=request.getHeader(OAMFilter.HEADER_USER_UID) %> <br/>	
USER_NAME: <%=request.getHeader(OAMFilter.HEADER_USER_NAME) %> <br/>
USER_EMAIL: <%=request.getHeader(OAMFilter.HEADER_USER_EMAIL) %> <br/>
USER_ID_FORNECEDOR: <%=request.getHeader(OAMFilter.HEADER_USER_ID_FORNECEDOR) %> <br/>
USER_PROVIDER_NAME: <%=request.getHeader(OAMFilter.HEADER_USER_PROVIDER_NAME) %> <br/>
USER_DEPARTAMENTO: <%=request.getHeader(OAMFilter.HEADER_USER_DEPARTAMENTO) %> <br/>
USER_SUPERIOR_IMEDIATO: <%=request.getHeader(OAMFilter.HEADER_USER_SUPERIOR_IMEDIATO) %> <br/>
AUTH_TYPE: <%=request.getHeader(OAMFilter.HEADER_AUTH_TYPE) %> <br/>
GROUPS: <%=request.getHeader(OAMFilter.HEADER_GROUPS) %> <br/>
<br/>
<br/>
<br/>

<strong>Dados do USUARIO AUTENTICADO...</strong>
<%
User userSessao = (User) session.getAttribute(SecurityConstant.SESSION_USER);
if(userSessao==null){
	out.println("Usuario nao informado");
}else{
%>	
UID: <%=userSessao.getUid() %> <br/>	
TipoUsuario: <%=userSessao.getTipoUsuario() %> <br/>
AuthType: <%=userSessao.getAuthType() %> <br/>
ProviderName: <%=userSessao.getProviderName() %> <br/>
NAME: <%=userSessao.getName() %> <br/>
FullName: <%=userSessao.getFullName() %> <br/>
Email: <%=userSessao.getEmail() %> <br/>
Address: <%=userSessao.getAddress() %> <br/>
ProviderInfo: <%=userSessao.getProviderInfo()%> <br/>
TipoAcesso: <%=(userSessao.getTipoAcesso()!=null?userSessao.getTipoAcesso().name():"NAO INFORMADO") %> <br/>
Pais: <%=(userSessao.getPais()!=null?userSessao.getPais().getName():"NAO INFORMADO") %> <br/>
ROLES: <%
Role[] roles = userSessao.getRoles();
for(Role role:roles){
	out.print(role.getName()+";");
}
%> <br/>

<%	
}
%>
